﻿window.netbooksApp.netbooksViewModel = (function(ko, datacontext) {
    var bookList = ko.observable(),
        error = ko.observable();
    
    datacontext.getBookList(bookList, error);

    return {
        bookList: bookList,
        error: error
    };
})(ko, netbooksApp.datacontext);

ko.applyBindings(window.netbooksApp.netbooksViewModel);